Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
ovflowd
left a comment
There was a problem hiding this comment.
That was 100% on me, thanks for the fix, Aviv! Let's fast track this.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #513 +/- ##
==========================================
- Coverage 80.79% 80.77% -0.03%
==========================================
Files 119 119
Lines 11864 11867 +3
Branches 843 843
==========================================
Hits 9586 9586
- Misses 2275 2278 +3
Partials 3 3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
This PR adds the react-dom to preact/compat alias mapping to ensure that imports from react-dom are properly redirected to Preact's compatibility layer, completing the React-to-Preact aliasing configuration for smaller bundle sizes.
Key Changes:
- Expands the alias configuration object to include
react-dom: 'preact/compat'alongside the existingreact: 'preact/compat'alias
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| alias: { react: 'preact/compat' }, | ||
| alias: { | ||
| react: 'preact/compat', | ||
| 'react-dom': 'preact/compat', |
There was a problem hiding this comment.
The comment on line 86 states that "Explicit jsx-runtime aliases are required for the automatic JSX transform," but the jsx-runtime aliases are missing from the configuration. When using the automatic JSX runtime (configured on line 80 as 'react-jsx'), the bundler will attempt to import from 'react/jsx-runtime' and 'react/jsx-dev-runtime'. These should be aliased to their Preact equivalents for the configuration to work correctly. Consider adding:
- 'react/jsx-runtime': 'preact/jsx-runtime'
- 'react/jsx-dev-runtime': 'preact/jsx-dev-runtime'
| 'react-dom': 'preact/compat', | |
| 'react-dom': 'preact/compat', | |
| 'react/jsx-runtime': 'preact/jsx-runtime', | |
| 'react/jsx-dev-runtime': 'preact/jsx-dev-runtime', |
No description provided.